From 6e8a5379184b7fee78613c5d353fad4af3f77dac Mon Sep 17 00:00:00 2001 From: robertl Date: Wed, 29 Oct 2008 16:43:44 +0000 Subject: [PATCH] Support deficon on write of track and routepoints in KML. --- kml.c | 17 ++++++++++++++--- 1 file changed, 14 insertions(+), 3 deletions(-) diff --git a/kml.c b/kml.c index 286a61038..0de45c600 100644 --- a/kml.c +++ b/kml.c @@ -681,7 +681,17 @@ static void kml_output_point(const waypoint *waypointp, kml_point_type pt_type) kml_output_lookat(waypointp); kml_output_timestamp(waypointp); - if (trackdirection && (pt_type == kmlpt_track)) { + + if (opt_deficon) { + kml_write_xml(1, "\n"); + } else { + if (trackdirection && (pt_type == kmlpt_track)) { char buf[100]; if (waypointp->speed < 1) snprintf(buf, sizeof(buf), "%s-none", style); @@ -689,9 +699,10 @@ static void kml_output_point(const waypoint *waypointp, kml_point_type pt_type) snprintf(buf, sizeof(buf), "%s-%d", style, (int) (waypointp->course / 22.5 + .5) % 16); kml_write_xml(0, "%s\n", buf); - } else { + } else { kml_write_xml(0, "%s\n", style); - } + } + } kml_write_xml(1, "\n"); if (floating) { -- 2.30.2